<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <title>Document</title>
        <style>
            .my-button{
                background-color: green;
            }
        </style>
    </head>
    <body>
        <div id="app">
            <functional-button 
            id="title"
            class="my-button"
            :style="{color:'red'}"
            :label="'Click'"></functional-button>
        </div>
        <script src="vue.js"></script>
        <script>
        Vue.component('functional-button',{
                functional:true,
                props:['label'],
                render(createElement,context){
                    console.log(context)
                    //data attr:{id:'title'} style staticClass
                    return createElement('button',context.data,context.props.label)
                }
        });
        var vm = new Vue({
            el:'#app',
           
        });
    </script>
    </body>
</html>